package com.yqw.onlineDocs.model.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 文档用户关联
 *
 * @TableName document_user
 */
@TableName(value = "document_user")
@Data
public class DocumentUser implements Serializable {

  /**
   * id
   */
  @TableId(type = IdType.AUTO)
  private Long id;

  /**
   * 文档id
   */
  private Long documentId;

  /**
   * 用户id
   */
  private Long userId;

  /**
   * 权限类型：viewer/editor/admin
   */
  private String permission;

  /**
   * 创建时间
   */
  private Date createTime;

  /**
   * 更新时间
   */
  private Date updateTime;

  /**
   * 是否删除
   */
  @TableLogic
  private Integer isDelete;

  @TableField(exist = false)
  private static final long serialVersionUID = 1L;
}